/// 响应主体内容
class WriteoffAmountStatisticsInfo {
  /// 卡种类id
  final int? cardTypeId;
  /// 卡种类名称
  final String? cardTypeName;
  /// 今天的核销额度，单位美元
  final int? todayAmount;
  /// 昨天的核销额度，单位美元
  final int? yestodayAmount;
  /// 截止当前总的核销额度，单位美元
  final int? totalAmount;

  WriteoffAmountStatisticsInfo({
    this.cardTypeId,
    this.cardTypeName,
    this.todayAmount,
    this.yestodayAmount,
    this.totalAmount,
  });

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = <String, dynamic>{};
    if (cardTypeId != null) data['cardTypeId'] = cardTypeId;
    if (cardTypeName != null) data['cardTypeName'] = cardTypeName;
    if (todayAmount != null) data['todayAmount'] = todayAmount;
    if (yestodayAmount != null) data['yestodayAmount'] = yestodayAmount;
    if (totalAmount != null) data['totalAmount'] = totalAmount;
    return data;
  }

  factory WriteoffAmountStatisticsInfo.fromJson(Map<String, dynamic> json) {
    return WriteoffAmountStatisticsInfo(
      cardTypeId: json['cardTypeId'],
      cardTypeName: json['cardTypeName'],
      todayAmount: json['todayAmount'],
      yestodayAmount: json['yestodayAmount'],
      totalAmount: json['totalAmount'],
    );
  }
}